﻿<%@ Page Language="C#" AutoEventWireup="true" CodeFile="WorkToNext.aspx.cs" Inherits="Flow_Info_WorkToNext" %>

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head runat="server">
    <title>无标题页</title>
    <script type="text/javascript" src="../js/Flow_Info.js"></script>
    <link href="../User/CSS/TableStyle.css" rel="stylesheet" />
    <link rel="Stylesheet" type="text/css" href="../Styles/right_style.css" />
    <script type="text/javascript" src="../Scripts/jquery.ui/js/jquery.js"></script>
    <style type="text/css">
        <!--
        html{ scrollbar-base-color: #dbecf8; scrollbar-arrow-color: #2a8ed1; scrollbar-track-color: #bdddf2; scrollbar-3dlight-color: #2886c5; scrollbar-darkshadow-color: #2886c5;
        scrollbar-face-color: #dbecf8; scrollbar-shadow-color: #dbecf8;  }
        -->
    </style>
</head>
<body>
    <form id="myFrm" name="myFrm" action="FindToNextUsers.aspx" method="post">
    <input name="FL_ID" type="hidden" value="<%=flow_id %>">
    <input name="ST_SO" type="hidden" value="<%=step_sort %>">
    <input name="WR_ID" type="hidden" value="<%=work_id %>">
    <input id="NT_ST" type="hidden" name="NT_ST" />
    </form>
    <form id="form1" runat="server">
    <div class="sub_right_top">
        <div class="hdm_footer">
            <div style="height: 13px; overflow: hidden;">
            </div>
            <% if (fnf != null)
               { %>
            <table width="97%" border="1" align="center" cellpadding="0" cellspacing="0" bordercolor="#77acd0"
                style="border-collapse: collapse;">
                <tr bgcolor="#b1d5ef">
                    <td align="center" colspan="2">
                        <b>
                            <%=fnf.Base_newflow_name %>
                        </b>
                    </td>
                </tr>
                <tr>
                    <td style="width: 40%">
                        <font style="font-size: 12px">第<%=fnf.Sort_id %>步:<%=fnf.Prc_name %>(当前步骤) </font>
                    </td>
                    <td>
                        <% foreach (object key in fnf.HtUser.Keys)
                           { %>
                        <% if (key.ToString().Equals(curLoginUser.LoginName))
                           { %>
                        <font style="font-size: 12px">
                            <%=fnf.HtUser[key].ToString() %>
                        </font>
                        <% } %>
                        <% } %>
                    </td>
                </tr>
                <tr>
                    <td align="center" colspan="2" height="25px">
                        <b>请选择下一步骤</b>
                    </td>
                </tr>
                <tr>
                    <td colspan="2">
                        <% if (fnf.HtNextStep != null)
                           { %>
                        <% foreach (object key in fnf.HtNextStep.Keys)
                           { %>
                        <font style="font-size: 12px">
                            <input type="radio" name="nextid" value="<%=key.ToString() %>" onclick="javascript:document.getElementById('NT_ST').value=this.value;myFrm.submit();" /><%=fnf.HtNextStep[key].ToString()%></font>
                        <% } %>
                        <% }
                           else
                           { %>
                        <% this.BtnToNext.Text = "结束工作"; %>
                        <script type="text/javascript">
                            document.write("<font style='font-size:12px'>无可选步骤,结束工作！</font>");
                        </script>
                        <% } %>
                    </td>
                </tr>
                <% 
               if (Session["NEXT_USERS"] != null)
               {
                   Hashtable ht_users = (Hashtable)Session["NEXT_USERS"]; 
                %>
                <tr>
                    <td colspan="2" style="height: 25px">
                        <input type="hidden" id="BACK_STEP" value="<%=(int)Session["NEXT_STEP"] %>" />
                        <script type="text/javascript">
                            var myEles = document.getElementsByTagName("input");
                            for (var i = 0; i < myEles.length; i++) {
                                if (myEles[i].type == "radio" && myEles[i].name == "nextid" && myEles[i].value == document.getElementById("BACK_STEP").value) {
                                    myEles[i].checked = true;
                                }
                            }   
                        </script>
                        <b>请指定下一步骤的经办人</b>
                    </td>
                </tr>
                <tr>
                    <td colspan="2" style="">
                        <% foreach (object key in ht_users.Keys)
                           { %>
                        <font style="font-size: 12px">
                            <input name="jingban" onclick="addToSelect('<%=ht_users[key].ToString() %>','<%=key.ToString() %>')"
                                type="checkbox" value="<%=key.ToString() %>" /><%=ht_users[key].ToString()%>
                        </font>
                        <% } %>
                    </td>
                </tr>
                <tr>
                    <td colspan="2" height="25px">
                        <b>指定主办人</b><select id="zhuban" name="zhuban" style="width: 143px"></select>
                        <b>仅允许主办人编辑表单正文、公共附件和转交流程</b>
                    </td>
                </tr>
                <% } %>
                <tr align="center">
                    <td colspan="2" style="height: 30px">
                        <asp:Button ID="BtnToNext" runat="server" OnClick="BtnToNext_Click" OnClientClick="return checkToNext()"
                            Text="转交下一步骤" />
                        <asp:Button ID="BtnBack" runat="server" Text="返回" Width="64px" OnClick="BtnBack_Click" />
                    </td>
                </tr>
            </table>
            <% }
               else
               { %>
            <script type="text/javascript">
                alert("信息加载异常，请重试！");
            </script>
            <% } %>
        </div>
    </div>
    </form>
</body>
</html>
